A Rscatter chart with a connecting line
This goes in the documents header:
<script src="RGraph.common.core.js"></script>
<script src="RGraph.rscatter.js"></script>
Put this where you want the chart to show up:
<canvas id="cvs" width="500" height="500">
[No canvas support]
</canvas>
This is the code that generates the chart:
<script>
var data = [],
data2 = [],
data3 = [];
for (var i=0; i<360; i+=2) {
data2.push([i, i, 'red']);
data.push([i, i * 3, 'green']);
data3.push([i, i * 6, 'blue']);
}
var rscatter = new RGraph.Rscatter({
id: 'cvs',
data: [data,data2, data3],
options: {
line: true,
lineColors: ['red', 'green', 'blue'],
lineClose: [false, false],
lineLinewidth: 2,
lineShadow: true,
lineShadowOffsetx: 1,
lineShadowOffsety: 1,
lineShadowBlur: 3,
tickmarks: null,
labelsAxes: 'n',
axesColor: 'rgba(0,0,0,0)',
textAccessible: true
}
}).draw();
</script>